function [e] = inverse_m(m,s,cobb_par,M,sf)
%This function computes the number of exporters searching that is implied
%given a vector m of matches and a vector s of ships searching
if sf==1
    e =  1./cobb_par(:,1);
    e = e./(s.^(1-cobb_par(:,2)));
    e = m./e;
    e = e.^(-cobb_par(:,2));
    for i = 1:M

        gamma_obs = cobb_par(i,2);
        e(i) = m(i)./cobb_par(i,1);
        e(i) = e(i)./(s(i).^(1-gamma_obs));
        e(i) = e(i).^(1/gamma_obs);
        if m(i)>e(i)
            e(i) = m(i);
        end

    end
else
    e = m;
    if s<e
        "ships are the short side of the mkt \n" %#ok<*NOPRT>
    end
end
end

